---
title: SAIF.Application.Claim operations and processes
summary: Operation catalog for claim/worker context management, security enforcement, and save lifecycle in the claim-context application manager library.
status: draft
owner: SAIF Claims BOF team
last_reviewed: 2026-08-21
library: SAIF.Application.Claim
reference_type: embedded
---

# SAIF.Application.Claim operations and processes

This page is the operation catalog and cross-operation hub for `SAIF.Application.Claim`. Each operation's detailed, step-by-step logic lives in its own page under `operations/`.

## Operation catalog
| Operation | Intent | Trigger | Inputs | Outputs | Rules |
| --- | --- | --- | --- | --- | --- |
| [Set claim context and retrieve](operations/set-claim-context-and-retrieve.md) | Establish the current claim context from a claim number or claim ID and retrieve claim data | Caller (concrete claim-screen application manager) supplies a claim number or claim ID | `inClaimNumber As String` or `inClaimID As Decimal` | Updated `Context`, `ClaimData`, `Message`, security state | [BR-CLM-001](business-rules.md#br-clm-001-conflict-claim-access-restriction), [BR-CLM-002](business-rules.md#br-clm-002-exposure-claim-access-restriction), [BR-CLM-003](business-rules.md#br-clm-003-health-issue-claim-access-restriction), [BR-CLM-004](business-rules.md#br-clm-004-hostile-secure-claim-access-restriction), [BR-CLM-006](business-rules.md#br-clm-006-blank-placeholder-claim-number-rejected), [BR-CLM-007](business-rules.md#br-clm-007-claim-not-found-messaging) |
| [Set worker context](operations/set-worker-context.md) | Establish the current context from a worker ID | Caller supplies a worker ID (e.g., navigation from a worker-centric screen) | `inWorkerID As Decimal` | Updated `Context`, `ClaimData`, security state | [BR-CLM-001](business-rules.md#br-clm-001-conflict-claim-access-restriction) through [BR-CLM-004](business-rules.md#br-clm-004-hostile-secure-claim-access-restriction) |
| [Security enforcement](operations/security-enforcement.md) | Recompute per-claim access flags and gate access on context change | Step 3 of `ChangeContext()`, whenever context is successfully set | Current `ClaimData` | `SecurityRole`, `Message` | [BR-CLM-001](business-rules.md#br-clm-001-conflict-claim-access-restriction), [BR-CLM-005](business-rules.md#br-clm-005-default-view-only-access-on-context-change) |
| [Save](operations/save-write.md) | Persist pending claim changes within a transaction | Caller requests persistence | None (in-memory state built by concrete subclass) | `Boolean` success/failure | None directly |
| [Save task list](operations/save-task-list.md) | Persist the current task list as part of a subclass save | Subclass calling it from its own `OnWrite()` implementation | None (`Tasks` collection state) | `Boolean` | None directly |
| [Establish data layer](operations/establish-data-layer.md) | Establish the Oracle data portal for the claim domain | Application manager initialization (inherited lifecycle) | None | Configured `DataLayer` DPI or thrown exception | None directly |

## Process flow diagram
The following diagram visualizes the primary operational flow from context change through security enforcement and retrieval.

```mermaid
flowchart TD
	Start([Caller sets claim/worker context]) --> Validate{Input valid?}
	Validate -->|No| Invalid([ClaimData cleared<br>MarkContextNotSet<br>Message: PLEASEENTERCLAIM])
	Validate -->|Yes| ChangeContext[ChangeContext]
	ChangeContext --> OnContextChanged[OnContextChanged:<br>GetClaimData]
	OnContextChanged --> Valid{ClaimData.IsValid?}
	Valid -->|No| NotFound([Message: CLAIMNOTFOUND<br>context not set])
	Valid -->|Yes| MarkSet[MarkContextSet]
	MarkSet --> Security[OnCheckSecurity:<br>CheckClaim + MarkViewOnly]
	Security --> Conflict{ConflictAccess or<br>SecurityOverride?}
	Conflict -->|No| Denied([MarkNoAccess<br>ConfidentialAccessDeniedMessage])
	Conflict -->|Yes| Retrieve[OnRetrieve<br>subclass-implemented]
```

## Database interactions

`SAIF.Application.Claim` performs no SQL of its own; all data reads/writes are delegated to externally-packaged business objects (`clsClaimData`, `clsEmployeeData`, `clsClaimTaskGenerator`) reached through the Oracle DPI established by [Establish data layer](operations/establish-data-layer.md). No `database-tables.md`/`sql/` documentation set is generated for this library.

## Failure and edge-case behavior
- Blank or placeholder ("claim #") claim number: rejected per [BR-CLM-006](business-rules.md#br-clm-006-blank-placeholder-claim-number-rejected).
- Claim data not retrievable for the set context: reported per [BR-CLM-007](business-rules.md#br-clm-007-claim-not-found-messaging).
- Worker ID `<= 0`: no context change, no message set — no explicit error handling*.
- Exception during `OnCreateDataLayer()`: context marked not set, access marked denied, wrapped `ApplicationException` re-thrown.
- Exception during `OnWrite()`: `OnTransactionStop(False)` explicitly forces rollback before re-throw; the `Finally` block's `OnTransactionStop(WriteResult)` may then also execute, potentially invoking `OnTransactionStop` twice on the exception path*.

## Related documentation
- [Index](index.md)
- [Overview](overview.md)
- [Architecture](architecture.md)
- [Dependencies](dependencies.md)
- [Business rules](business-rules.md)
- [Security and authorization](security-authorization.md)
- [Configuration](configuration.md)
- [API reference](api/index.md)

> **Note:** Statements marked with * were inferred from code structure, naming conventions, or
> contextual evidence where direct confirmation was not available in source artifacts. Statements
> marked with ** could not be confirmed; treat as unknown until verified.

## Sources
- `SAIF.Application.Claim\ClaimAppManager.vb`
- `SAIF.Application.Claim\ClaimSecurity.vb`
- `SAIF.Application.Claim\ClaimAppConstants.vb`
